<template>
  <div class="home">
    <img alt="Vue logo" src="../assets/logo.png">
    <HelloWorld msg="Hello Word"/>
    <Hey></Hey>
  </div>
</template>

<script>
// @ is an alias to /src
import HelloWorld from '@/components/HelloWorld.vue'
import Hey from '@/components/Hey'
export default {
  name: 'Home',
  // 爷孙隔代传值
  // provide: {
  //   foo: 'foo'
  // },
  provide () {
    return {
      foo: this.tua
    }
  },
  data () {
    return {
      tua: 'tua'
    }
  },
  components: {
    HelloWorld, Hey
  }
}
</script>
